home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Amiga Plus Special 17
/
AMIGAplus Sonderheft 17 (1999)(ICP)(DE)[!].iso
/
Rexx
/
E!XI
/
E!XI.rexx
< prev
Wrap
OS/2 REXX Batch file
|
1997-07-21
|
3KB
|
114 lines
/* $VER: Excelsior!'s_Xtruder_Interface 2.1 (1.10.95) © 1995 Alex Holst/SHI
This script is freeware, and may be copied as long as no changes
are made to the contents of the original distribution archive.
Filename check original code by Tobias Biehl (2:235/314.46@fidonet)
Requires Xtruder 2.0
Flames to dev/null. Bugreports, suggestions and women to..
Alex Holst, SHI
2:238/127.0@fidonet
39:140/136.0@amiganet
*/
LOG = 'E:Text/logs/E!XI.log' /* Path and name of your logfile. */
Badlist = 'E:EX.BadFiles' /* Set your Ascii file with warns here. */
/*
··············································································
DO NOT EDIT BELOW THIS LINE
··············································································
*/
ADDRESS XTRUDER
OPTIONS RESULTS
PARSE UPPER ARG arg2
archive = arg2
/*************************** Argument Check ************************/
If archive = '?' then do
say ''
say '
E!XI 2.1 © Alex Holst for SHI
'
say ''
say ' Usage: rx E!XI.rexx FILENAME/A'
say ''
say 'E!XI will ask Xtruder to check the file'
say 'you specify as argument. If this is an'
say 'archive it will be uncrunched with the'
say 'settings you have chosen for Xtruder.'
say ''
Exit 0
End
IF archive = '' then do
say 'Required argument missing.'
exit 0
END
/*************************** Open File(s) ***************************/
BADVAR = 'TRUE'
IF ~Open(ScanFil,Badlist,R) Then Do
Say "E!XI Error: Couldn't find your Badlist! Check your settings in the script."
BADVAR = 'FALSE'
End
IF ~Open(ReadLog,LOG,A) then do
Say "E!XI Error: Unable to write to LOG!"
Exit 0
End
/************************ Start Check ********************************/
say 'E!XI 2.1 by Alex Holst/SHI'
say ''
say 'Checking 'archive' for virus...'
Call WriteLn(ReadLog,'< '||Date()||' 'Time()||' Xtruder started check of 'archive)
CHECKFILES archive
filestatus = rc
IF filestatus = -1 THEN DO
say 'E!XI Error: Could not find 'archive'!'
Call WriteLn(ReadLog,'+ '||Date()||' 'Time()||' 'archive' not found! Exiting.')
Exit 0
END
IF BADVAR = 'TRUE' THEN DO
Say "Checking EX.BadFiles list..."
Call WriteLn(ReadLog,'+ '||Date()||' 'Time()||' Comparing 'archive' against BadList')
Do Until EOF(ScanFil) = 1
Line = ReadLn(ScanFil)
IF UPPER(Line) = UPPER(file) Then do
Say ""
Say "This file is listed as dangerous!"
Call WriteLn(ReadLog,'! '||Date()||' 'Time()||' 'archive' is listed as dangerous!')
Exit 0
END
END
IF filestatus = 0 THEN DO
Call WriteLn(ReadLog,'+ '||Date()||' 'Time()||' Xtruder found nothing in 'archive)
say 'Archive contains no vira.'
say 'Ok!'
END
IF filestatus >= 1 THEN DO
say archive' seem to contain a virus!'
Call WriteLn(ReadLog,'! '||Date()||' 'Time()||' Xtruder found virus in 'archive'!')
address command 'run <Nil: >nil: doors:E!XI/E!XI-FV'
END
END
Call WriteLn(ReadLog,'< '||Date()||' 'Time()||' Xtruder ended check of 'archive)
Call Close LOG
Call Close BadList
EXIT 0
END